package com.hzhc.enumBean;

/**
 * SendTransportState
 *
 * @author shizj
 */
public enum SendTransportState {

    CONTINUE_SEND_TRANSPORT(0, "继续发运"),
    CANCEL_SEND_TRANSPORT(1, "取消发运");

    private Integer code;

    private String name;

    private SendTransportState(Integer code, String name) {
        this.code = code;
        this.name = name;
    }

    public Integer getCode() {
        return code;
    }

    public String getName() {
        return name;
    }

    public String getNameByCode(Integer code) {
        switch (code) {
            case 0:
                return CONTINUE_SEND_TRANSPORT.getName();
            case 1:
                return CANCEL_SEND_TRANSPORT.getName();
            default:
                return "";
        }
    }
}
